package edu.udlap.spring2008.is300.finalexam.app;

import edu.udlap.spring2008.is300.finalexam.app.mvc.model.AppModel;
import edu.udlap.spring2008.is300.finalexam.app.mvc.model.database.objects.AppCategoryRecord;
import edu.udlap.spring2008.is300.finalexam.app.mvc.model.database.objects.AppFormatRecord;
import edu.udlap.spring2008.is300.finalexam.app.mvc.model.database.objects.AppImageRecord;
import edu.udlap.spring2008.is300.finalexam.app.mvc.model.database.objects.AppPrivacyLevelRecord;
import edu.udlap.spring2008.is300.finalexam.app.mvc.model.database.objects.AppSizeRecord;
import edu.udlap.spring2008.is300.finalexam.app.mvc.view.AppViewFactory;
import edu.udlap.spring2008.is300.finalexam.framework.mvc.model.Model;
import edu.udlap.spring2008.is300.finalexam.framework.mvc.view.ViewComponent;
import edu.udlap.spring2008.is300.finalexam.framework.mvc.view.ViewFactory;

/**
 *
 * @author Ruslán Ledesma Garza
 */
public class Main
{
    /**
     * @param args the command line arguments
     */
    public static void main(String[] args)
    {
        
        //ModelTest();
                

        ///create & initialize model...
        Model model = new AppModel();
        model.initialize();
        
        //InsertNewImage(model);
        
        ///create view factory...
        ViewFactory viewFactory = new AppViewFactory();
        
        ///create views...
        ViewComponent view1 = viewFactory.newStandardView("My Java Image Library", model);
    }
    
    /*
    private static void InsertNewImage(Model model)
    {
        model.addImageRecord(new AppImageRecord(0, "D:\\Documents\\Documents\\NetBeansProjects\\is300.finalexam\\imgs", true, "YEAH",
                new AppCategoryRecord(1,""),
                new AppSizeRecord(1, ""),
                new AppFormatRecord(1, ""),
                new AppPrivacyLevelRecord(1, "")));
    }*/
    
    /*
    private static void ModelTest()
    {
        Model model = new AppModel();
        
        model.initialize();

        ArrayList<ImageRecord> images = model.getAllImageRecords();
        
        for(int i = 0; i<images.size(); i++)
            System.out.println(images.get(i));
        
        model.addImageRecord(new AppImageRecord(0, "EAEAEAE", true, "YEAH",
                new AppCategoryRecord(1,""),
                new AppSizeRecord(1, ""),
                new AppFormatRecord(1, ""),
                new AppPrivacyLevelRecord(1, "")));

        images = model.getAllImageRecords();
        
        for(int i = 0; i<images.size(); i++)
            System.out.println(images.get(i));

    }
     * */
}
